var path = require('path'),
    rootPath = path.normalize(__dirname + '/..'),
    env = process.env.NODE_ENV || 'development';
var config = {
    development: {
        root: rootPath,
        app: {
            cn: '开发环境',
            name: 'development'
        },
        resourcePath:{
            staticRoot:'',
            leisuCdn : '//cdn.leisu.com',
            wwwRoot : 'http://www.leisu.com',
            apiRoot : 'http://code.haier.net:403',
            // redirectRoot:'http://123.103.113.65/'
            redirectRoot:'http://hrfwtest2.haier.net/'
            // apiRoot : 'http://10.138.111.98:403'
        },
        port: process.env.PORT || 80,
    },
    test: {
        root: rootPath,
        app: {
            cn: '测试环境',
            name: 'test'
        },
        resourcePath:{
            staticRoot:'http://test.leisu.com:80',
            leisuCdn : '//cdn.leisu.com',
            wwwRoot : 'http://www.leisu.com',
            apiRoot : 'http://code.haier.net:403',
            // redirectRoot:'http://123.103.113.65/'
            redirectRoot:'http://hrfwtest2.haier.net/'
        },
        port: process.env.PORT || 80,
    },
    production: {
        root: rootPath,
        app: {
            cn: '正式环境',
            name: 'production'
        },
        resourcePath:{
            staticRoot:'http://res.leisu.com',
            leisuCdn : '//cdn.leisu.com',
            wwwRoot : 'http://www.leisu.com',
            apiRoot : 'http://code.haier.net:403',
            // redirectRoot:'http://123.103.113.65/'
            redirectRoot:'http://hrfwtest2.haier.net/'
        },
        port: process.env.PORT || 80,
    }
};
module.exports = config[env];
